import React from 'react';
import { Button, Progress } from 'antd-mobile';

import http from '../../assets/js/http';

import './user.less';

function User() {
  let getdata = () => {
    http.post('/action/kepu', { storeId: 1 }).then((e) => {
      console.log(e);
    });
  };

  // let getdata2 = async () => {
  //   let reslut = await http.post('/action/kepu', { storeId: 1 });

  //   console.log(reslut);
  // };
  return (
    <div className='v-user'>
      <Button onClick={getdata}>点击测试跨域请求</Button>
      <p> 使用 /libs/theme.js 修改默认主题</p>
      <Progress percent={30} position='normal' />
    </div>
  );
}

export default User;
